<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script>
		window.onload= function () {
			box = document.getElementById('box');
			box1 = document.getElementById('box1');
			span1 = document.getElementById('span1');

			a = document.createElement('a');

			a.innerHTML = "百度一下";

			a.href = "http://www.baidu.com";

			a.id = "baidu"

			// box.appendChild(a);

			// box.insertBefore(a,span1);
			// box.removeChild(span1);
			// box.replaceChild(a,span1);
			// 
			newspan = span1.cloneNode(true);

			box1.appendChild(newspan);
		}
	</script>
</head>
<body>
	<p id="box">
		<i>这个是i</i>
		<span id="span1">span</span>
	</p>
	<p id='box1'>
		
	</p>
</body>
</html>